<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>rest_client_c: include/rest_client.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">rest_client_c
   &#160;<span id="projectnumber">1.0</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.1.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('rest__client_8h.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Data Structures</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Pages</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="headertitle">
<div class="title">rest_client.h</div>  </div>
</div><!--header-->
<div class="contents">
<a href="rest__client_8h.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="comment">/*</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="comment"> Copyright (c) 2012, EMC Corporation</span></div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="comment"> All rights reserved.</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="comment"> Redistribution and use in source and binary forms, with or without</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="comment"> modification, are permitted provided that the following conditions are met:</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="comment"> * Redistributions of source code must retain the above copyright notice, this</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="comment">   list of conditions and the following disclaimer.</span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="comment"> * Redistributions in binary form must reproduce the above copyright notice,</span></div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="comment">   this list of conditions and the following disclaimer in the documentation</span></div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="comment">   and/or other materials provided with the distribution.</span></div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;<span class="comment"> * Neither the name of the EMC Corporation nor the names of its contributors</span></div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="comment">   may be used to endorse or promote products derived from this software</span></div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;<span class="comment">   without specific prior written permission.</span></div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;<span class="comment"> THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS &quot;AS IS&quot;</span></div>
<div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;<span class="comment"> AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE</span></div>
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;<span class="comment"> IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE</span></div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;<span class="comment"> DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE</span></div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;<span class="comment"> FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL</span></div>
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;<span class="comment"> DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR</span></div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;<span class="comment"> SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER</span></div>
<div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;<span class="comment"> CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,</span></div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;<span class="comment"> OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE</span></div>
<div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;<span class="comment"> OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.</span></div>
<div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;<span class="comment">*/</span></div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;</div>
<div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;<span class="preprocessor">#ifndef REST_CLIENT_H_</span></div>
<div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define REST_CLIENT_H_</span></div>
<div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;<span class="preprocessor">#include &lt;curl/curl.h&gt;</span></div>
<div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;<span class="preprocessor">#ifdef _PTHREADS</span></div>
<div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#include &lt;pthread.h&gt;</span></div>
<div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="object_8h.html" title="This module contains the base object class definition and its methods.">object.h</a>&quot;</span></div>
<div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;</div>
<div class="line"><a name="l00056"></a><span class="lineno"><a class="code" href="group__REST__API_gab8949645fa8d90e1722d233c6bdfc815.html#gab8949645fa8d90e1722d233c6bdfc815">   56</a></span>&#160;<span class="preprocessor">#define MAX_HEADERS 64</span></div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00060"></a><span class="lineno"><a class="code" href="group__REST__API_gadfb08e31817eba31a39cbab6810f5756.html#gadfb08e31817eba31a39cbab6810f5756">   60</a></span>&#160;<span class="preprocessor">#define ERROR_MESSAGE_SIZE 255</span></div>
<div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;</div>
<div class="line"><a name="l00066"></a><span class="lineno"><a class="code" href="group__REST__API_gaacd5f203e33ac338ca5cb8f02a3ff3b8.html#gaacd5f203e33ac338ca5cb8f02a3ff3b8">   66</a></span>&#160;<span class="keyword">enum</span> <a class="code" href="group__REST__API_gaacd5f203e33ac338ca5cb8f02a3ff3b8.html#gaacd5f203e33ac338ca5cb8f02a3ff3b8" title="Allowed methods for REST operations.">http_method</a> {</div>
<div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;        POST,</div>
<div class="line"><a name="l00068"></a><span class="lineno">   68</span>&#160;        GET,</div>
<div class="line"><a name="l00069"></a><span class="lineno">   69</span>&#160;        PUT,</div>
<div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160;        DELETE,</div>
<div class="line"><a name="l00071"></a><span class="lineno">   71</span>&#160;        HEAD,</div>
<div class="line"><a name="l00072"></a><span class="lineno">   72</span>&#160;        OPTIONS</div>
<div class="line"><a name="l00073"></a><span class="lineno">   73</span>&#160;};</div>
<div class="line"><a name="l00074"></a><span class="lineno">   74</span>&#160;</div>
<div class="line"><a name="l00076"></a><span class="lineno"><a class="code" href="group__REST__API_ga8f0595c28440225b49d757497cadf02a.html#ga8f0595c28440225b49d757497cadf02a">   76</a></span>&#160;<span class="preprocessor">#define CLASS_REST_RESPONSE &quot;RestResponse&quot;</span></div>
<div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00082"></a><span class="lineno"><a class="code" href="structRestResponse.html">   82</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span>{</div>
<div class="line"><a name="l00084"></a><span class="lineno"><a class="code" href="group__REST__API_ga4372ccd44ab3cdeaabd3c2ab806510a3.html#ga4372ccd44ab3cdeaabd3c2ab806510a3">   84</a></span>&#160;        <a class="code" href="structObject.html" title="The base Object class structure contains the textual name of the class; useful for debugging...">Object</a> <a class="code" href="group__REST__API_ga4372ccd44ab3cdeaabd3c2ab806510a3.html#ga4372ccd44ab3cdeaabd3c2ab806510a3" title="Parent class&#39;s fields.">parent</a>;</div>
<div class="line"><a name="l00094"></a><span class="lineno"><a class="code" href="group__REST__API_ga85a61f90362e9f93e702cad1032d468f.html#ga85a61f90362e9f93e702cad1032d468f">   94</a></span>&#160;        <span class="keywordtype">int</span> <a class="code" href="group__REST__API_ga85a61f90362e9f93e702cad1032d468f.html#ga85a61f90362e9f93e702cad1032d468f" title="HTTP code of the last operation.">http_code</a>;</div>
<div class="line"><a name="l00100"></a><span class="lineno"><a class="code" href="group__REST__API_ga6e3399e311a316ac012548a94234037c.html#ga6e3399e311a316ac012548a94234037c">  100</a></span>&#160;        <span class="keywordtype">char</span> http_status[<a class="code" href="group__REST__API_gadfb08e31817eba31a39cbab6810f5756.html#gadfb08e31817eba31a39cbab6810f5756" title="Compile-time constant for the maximum size of an error message.">ERROR_MESSAGE_SIZE</a>];</div>
<div class="line"><a name="l00106"></a><span class="lineno"><a class="code" href="group__REST__API_ga130c895035dbbf0b5c2078850ddc6b79.html#ga130c895035dbbf0b5c2078850ddc6b79">  106</a></span>&#160;        <span class="keywordtype">int</span> <a class="code" href="group__REST__API_ga130c895035dbbf0b5c2078850ddc6b79.html#ga130c895035dbbf0b5c2078850ddc6b79" title="Error code from libcurl.">curl_error</a>;</div>
<div class="line"><a name="l00110"></a><span class="lineno"><a class="code" href="group__REST__API_ga07ffe62eff3ae6cc18ba3710d7e7de79.html#ga07ffe62eff3ae6cc18ba3710d7e7de79">  110</a></span>&#160;        <span class="keywordtype">char</span> curl_error_message[CURL_ERROR_SIZE];</div>
<div class="line"><a name="l00112"></a><span class="lineno"><a class="code" href="group__REST__API_ga573727c86da0b377b7d0bb87f69908a1.html#ga573727c86da0b377b7d0bb87f69908a1">  112</a></span>&#160;        <span class="keywordtype">char</span> *response_headers[<a class="code" href="group__REST__API_gab8949645fa8d90e1722d233c6bdfc815.html#gab8949645fa8d90e1722d233c6bdfc815" title="Compile-time constant for the maximum number of HTTP headers to be passed in a single RestRequest...">MAX_HEADERS</a>];</div>
<div class="line"><a name="l00114"></a><span class="lineno"><a class="code" href="group__REST__API_ga882bbdbf00fa03923dce4899e36740b5.html#ga882bbdbf00fa03923dce4899e36740b5">  114</a></span>&#160;        <span class="keywordtype">int</span> <a class="code" href="group__REST__API_ga882bbdbf00fa03923dce4899e36740b5.html#ga882bbdbf00fa03923dce4899e36740b5" title="Number of response headers present in the response_headers array.">response_header_count</a>;</div>
<div class="line"><a name="l00119"></a><span class="lineno"><a class="code" href="group__REST__API_ga4f673cbc9fd671e9e45e44286cc47028.html#ga4f673cbc9fd671e9e45e44286cc47028">  119</a></span>&#160;        <span class="keywordtype">char</span> *<a class="code" href="group__REST__API_ga4f673cbc9fd671e9e45e44286cc47028.html#ga4f673cbc9fd671e9e45e44286cc47028" title="Content type of the response.">content_type</a>;</div>
<div class="line"><a name="l00125"></a><span class="lineno"><a class="code" href="group__REST__API_gaf4b21f9ce17e9d44e6049a30c887d2c2.html#gaf4b21f9ce17e9d44e6049a30c887d2c2">  125</a></span>&#160;        off_t <a class="code" href="group__REST__API_gaf4b21f9ce17e9d44e6049a30c887d2c2.html#gaf4b21f9ce17e9d44e6049a30c887d2c2" title="Bytes in the response.">content_length</a>;</div>
<div class="line"><a name="l00129"></a><span class="lineno"><a class="code" href="group__REST__API_ga383cc64782778a32743eb846031e6c5e.html#ga383cc64782778a32743eb846031e6c5e">  129</a></span>&#160;        <span class="keywordtype">char</span> *<a class="code" href="group__REST__API_ga383cc64782778a32743eb846031e6c5e.html#ga383cc64782778a32743eb846031e6c5e" title="The buffer containing the response body.">body</a>;</div>
<div class="line"><a name="l00135"></a><span class="lineno"><a class="code" href="group__REST__API_gac6ae52e6316f7819901ba5fd818f8425.html#gac6ae52e6316f7819901ba5fd818f8425">  135</a></span>&#160;    <span class="keywordtype">size_t</span> <a class="code" href="group__REST__API_gac6ae52e6316f7819901ba5fd818f8425.html#gac6ae52e6316f7819901ba5fd818f8425" title="If use_buffer is nonzero, this is the maximum number of bytes that can be written into the body buffe...">buffer_size</a>;</div>
<div class="line"><a name="l00142"></a><span class="lineno"><a class="code" href="group__REST__API_gae2485658ff0501edb5274641964ba31f.html#gae2485658ff0501edb5274641964ba31f">  142</a></span>&#160;    <span class="keywordtype">int</span> <a class="code" href="group__REST__API_gae2485658ff0501edb5274641964ba31f.html#gae2485658ff0501edb5274641964ba31f" title="If nonzero, the user has provided us with a static buffer to fill with the response.">use_buffer</a>;</div>
<div class="line"><a name="l00147"></a><span class="lineno"><a class="code" href="group__REST__API_ga6955db18d63c89803e6cabf9602bd7fc.html#ga6955db18d63c89803e6cabf9602bd7fc">  147</a></span>&#160;        FILE *<a class="code" href="group__REST__API_ga6955db18d63c89803e6cabf9602bd7fc.html#ga6955db18d63c89803e6cabf9602bd7fc" title="If not-NULL, the response body will be written to this file handle instead of memory.">file_body</a>;</div>
<div class="line"><a name="l00148"></a><span class="lineno">  148</span>&#160;} <a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a>;</div>
<div class="line"><a name="l00149"></a><span class="lineno">  149</span>&#160;</div>
<div class="line"><a name="l00155"></a><span class="lineno">  155</span>&#160;<a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a> *<a class="code" href="group__REST__API_ga7729c76a3f1f4ea7dbe68f5e6fb804eb.html#ga7729c76a3f1f4ea7dbe68f5e6fb804eb" title="Initializes a RestResponse object.">RestResponse_init</a>(<a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a> *<span class="keyword">self</span>);</div>
<div class="line"><a name="l00160"></a><span class="lineno">  160</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_ga29c2764d71d33ab560b68d6568862140.html#ga29c2764d71d33ab560b68d6568862140" title="Destroys a RestResponse object.">RestResponse_destroy</a>(<a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a> *<span class="keyword">self</span>);</div>
<div class="line"><a name="l00166"></a><span class="lineno">  166</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_gacfb1b3591c0868201babf7adcbd28582.html#gacfb1b3591c0868201babf7adcbd28582" title="Adds an HTTP response header to the object.">RestResponse_add_header</a>(<a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a> *<span class="keyword">self</span>, <span class="keyword">const</span> <span class="keywordtype">char</span> *header);</div>
<div class="line"><a name="l00177"></a><span class="lineno">  177</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_ga0e73480ef2ae6e69043f511604a83f19.html#ga0e73480ef2ae6e69043f511604a83f19" title="This function can be used to preconfigure a static response buffer to capture the response...">RestResponse_use_buffer</a>(<a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a> *<span class="keyword">self</span>, <span class="keywordtype">char</span> *buffer,</div>
<div class="line"><a name="l00178"></a><span class="lineno">  178</span>&#160;                             <span class="keywordtype">size_t</span> buffer_size);</div>
<div class="line"><a name="l00186"></a><span class="lineno">  186</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_ga60e4231fb371043ea1e1930296314d38.html#ga60e4231fb371043ea1e1930296314d38" title="This function can be used to configure the RestResponse to store the response body in a file...">RestResponse_use_file</a>(<a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a> *<span class="keyword">self</span>, FILE *f);</div>
<div class="line"><a name="l00187"></a><span class="lineno">  187</span>&#160;</div>
<div class="line"><a name="l00188"></a><span class="lineno">  188</span>&#160;<span class="preprocessor">#pragma mark RestRequestBody</span></div>
<div class="line"><a name="l00189"></a><span class="lineno">  189</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00193"></a><span class="lineno"><a class="code" href="structRestRequestBody.html">  193</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span>{</div>
<div class="line"><a name="l00195"></a><span class="lineno"><a class="code" href="group__REST__API_ga14dc79399d9b029c58d3293829933354.html#ga14dc79399d9b029c58d3293829933354">  195</a></span>&#160;        <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="group__REST__API_ga14dc79399d9b029c58d3293829933354.html#ga14dc79399d9b029c58d3293829933354" title="Type of content, e.g.">content_type</a>;</div>
<div class="line"><a name="l00197"></a><span class="lineno"><a class="code" href="group__REST__API_ga4f04ad0761b64ab07e5becd2a3e79950.html#ga4f04ad0761b64ab07e5becd2a3e79950">  197</a></span>&#160;        off_t <a class="code" href="group__REST__API_ga4f04ad0761b64ab07e5becd2a3e79950.html#ga4f04ad0761b64ab07e5becd2a3e79950" title="Number of bytes to write.">data_size</a>;</div>
<div class="line"><a name="l00199"></a><span class="lineno"><a class="code" href="group__REST__API_gab64d46b9833a6e3ac2870ceafc9e9b17.html#gab64d46b9833a6e3ac2870ceafc9e9b17">  199</a></span>&#160;        off_t <a class="code" href="group__REST__API_gab64d46b9833a6e3ac2870ceafc9e9b17.html#gab64d46b9833a6e3ac2870ceafc9e9b17" title="Bytes written to the request stream.">bytes_written</a>;</div>
<div class="line"><a name="l00201"></a><span class="lineno"><a class="code" href="group__REST__API_ga462dc7c41f1562cd9a1639bc0229f803.html#ga462dc7c41f1562cd9a1639bc0229f803">  201</a></span>&#160;        off_t <a class="code" href="group__REST__API_ga462dc7c41f1562cd9a1639bc0229f803.html#ga462dc7c41f1562cd9a1639bc0229f803" title="Bytes remaining to write to the request stream.">bytes_remaining</a>;</div>
<div class="line"><a name="l00203"></a><span class="lineno"><a class="code" href="group__REST__API_ga47974a523f5fcddf9025c09ba69aa088.html#ga47974a523f5fcddf9025c09ba69aa088">  203</a></span>&#160;        <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="group__REST__API_ga47974a523f5fcddf9025c09ba69aa088.html#ga47974a523f5fcddf9025c09ba69aa088" title="Memory buffer containing the request (NULL if using file_body)">body</a>;</div>
<div class="line"><a name="l00205"></a><span class="lineno"><a class="code" href="group__REST__API_gac93686e2abff8bf6aeaa58bd167374a5.html#gac93686e2abff8bf6aeaa58bd167374a5">  205</a></span>&#160;        FILE *<a class="code" href="group__REST__API_gac93686e2abff8bf6aeaa58bd167374a5.html#gac93686e2abff8bf6aeaa58bd167374a5" title="File pointiner containing the request data (NULL if using body)">file_body</a>;</div>
<div class="line"><a name="l00206"></a><span class="lineno">  206</span>&#160;} <a class="code" href="structRestRequestBody.html" title="Defines a RestRequestBody that is an optional component to a RestRequest.">RestRequestBody</a>;</div>
<div class="line"><a name="l00207"></a><span class="lineno">  207</span>&#160;</div>
<div class="line"><a name="l00208"></a><span class="lineno">  208</span>&#160;<span class="preprocessor">#pragma mark RestRequest</span></div>
<div class="line"><a name="l00209"></a><span class="lineno">  209</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00211"></a><span class="lineno"><a class="code" href="group__REST__API_ga05e7ba50b59a37c411ed334a42f5bb97.html#ga05e7ba50b59a37c411ed334a42f5bb97">  211</a></span>&#160;<span class="preprocessor">#define CLASS_REST_REQUEST &quot;RestRequest&quot;</span></div>
<div class="line"><a name="l00212"></a><span class="lineno">  212</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00218"></a><span class="lineno"><a class="code" href="structRestRequest.html">  218</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span>{</div>
<div class="line"><a name="l00220"></a><span class="lineno"><a class="code" href="group__REST__API_ga5defa6b00f8f5eaac419a16d703ce89f.html#ga5defa6b00f8f5eaac419a16d703ce89f">  220</a></span>&#160;        <a class="code" href="structObject.html" title="The base Object class structure contains the textual name of the class; useful for debugging...">Object</a> <a class="code" href="group__REST__API_ga5defa6b00f8f5eaac419a16d703ce89f.html#ga5defa6b00f8f5eaac419a16d703ce89f" title="Parent class&#39;s fields.">parent</a>;</div>
<div class="line"><a name="l00222"></a><span class="lineno"><a class="code" href="group__REST__API_ga1ab47fa3b2878d6f8e81609d884495ca.html#ga1ab47fa3b2878d6f8e81609d884495ca">  222</a></span>&#160;        <span class="keyword">enum</span> <a class="code" href="group__REST__API_gaacd5f203e33ac338ca5cb8f02a3ff3b8.html#gaacd5f203e33ac338ca5cb8f02a3ff3b8" title="Allowed methods for REST operations.">http_method</a> <a class="code" href="group__REST__API_ga1ab47fa3b2878d6f8e81609d884495ca.html#ga1ab47fa3b2878d6f8e81609d884495ca" title="The HTTP operation for the request (e.g.">method</a>;</div>
<div class="line"><a name="l00224"></a><span class="lineno"><a class="code" href="group__REST__API_gac06040805bc8b39a5246e876dafe2f4c.html#gac06040805bc8b39a5246e876dafe2f4c">  224</a></span>&#160;        <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="group__REST__API_gac06040805bc8b39a5246e876dafe2f4c.html#gac06040805bc8b39a5246e876dafe2f4c" title="The URI for the request (e.g.">uri</a>;</div>
<div class="line"><a name="l00226"></a><span class="lineno"><a class="code" href="group__REST__API_gab85209cefe45575c818af715d9a49d5c.html#gab85209cefe45575c818af715d9a49d5c">  226</a></span>&#160;        <span class="keywordtype">char</span> *headers[<a class="code" href="group__REST__API_gab8949645fa8d90e1722d233c6bdfc815.html#gab8949645fa8d90e1722d233c6bdfc815" title="Compile-time constant for the maximum number of HTTP headers to be passed in a single RestRequest...">MAX_HEADERS</a>];</div>
<div class="line"><a name="l00228"></a><span class="lineno"><a class="code" href="group__REST__API_ga9f988ab7e670fb3f0bf64663a0d6b1e6.html#ga9f988ab7e670fb3f0bf64663a0d6b1e6">  228</a></span>&#160;        <span class="keywordtype">int</span> <a class="code" href="group__REST__API_ga9f988ab7e670fb3f0bf64663a0d6b1e6.html#ga9f988ab7e670fb3f0bf64663a0d6b1e6" title="Number of request headers.">header_count</a>;</div>
<div class="line"><a name="l00233"></a><span class="lineno"><a class="code" href="group__REST__API_gacb466a60f781ea59c2922a1a68a3b9ef.html#gacb466a60f781ea59c2922a1a68a3b9ef">  233</a></span>&#160;        <a class="code" href="structRestRequestBody.html" title="Defines a RestRequestBody that is an optional component to a RestRequest.">RestRequestBody</a> *<a class="code" href="group__REST__API_gacb466a60f781ea59c2922a1a68a3b9ef.html#gacb466a60f781ea59c2922a1a68a3b9ef" title="Optional body for the request.">request_body</a>;</div>
<div class="line"><a name="l00234"></a><span class="lineno">  234</span>&#160;} <a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a>;</div>
<div class="line"><a name="l00235"></a><span class="lineno">  235</span>&#160;</div>
<div class="line"><a name="l00243"></a><span class="lineno">  243</span>&#160;<a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a> *<a class="code" href="group__REST__API_ga4ed741041689f0ba0af5aa9ae2425b90.html#ga4ed741041689f0ba0af5aa9ae2425b90" title="Initializes a new RestRequest object.">RestRequest_init</a>(<a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a> *<span class="keyword">self</span>, <span class="keyword">const</span> <span class="keywordtype">char</span> *uri,</div>
<div class="line"><a name="l00244"></a><span class="lineno">  244</span>&#160;                <span class="keyword">enum</span> <a class="code" href="group__REST__API_gaacd5f203e33ac338ca5cb8f02a3ff3b8.html#gaacd5f203e33ac338ca5cb8f02a3ff3b8" title="Allowed methods for REST operations.">http_method</a> method);</div>
<div class="line"><a name="l00249"></a><span class="lineno">  249</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_ga1643c4796e06226308ad1d8c19e4f116.html#ga1643c4796e06226308ad1d8c19e4f116" title="Destroys a RestRequest.">RestRequest_destroy</a>(<a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a> *<span class="keyword">self</span>);</div>
<div class="line"><a name="l00258"></a><span class="lineno">  258</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_gac7d92fd0aed40011a34fe4fa2cf70421.html#gac7d92fd0aed40011a34fe4fa2cf70421" title="Sets the RestRequest&#39;s body to an in-memory byte array.">RestRequest_set_array_body</a>(<a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a> *<span class="keyword">self</span>, <span class="keyword">const</span> <span class="keywordtype">char</span> *data,</div>
<div class="line"><a name="l00259"></a><span class="lineno">  259</span>&#160;                off_t data_size, <span class="keyword">const</span> <span class="keywordtype">char</span> *content_type);</div>
<div class="line"><a name="l00268"></a><span class="lineno">  268</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_ga322429d39996b9fff6c80dd2d3acf22b.html#ga322429d39996b9fff6c80dd2d3acf22b" title="Sets the RestRequest&#39;s body to the contents of a file pointer.">RestRequest_set_file_body</a>(<a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a> *<span class="keyword">self</span>, FILE *data, off_t data_size,</div>
<div class="line"><a name="l00269"></a><span class="lineno">  269</span>&#160;                <span class="keyword">const</span> <span class="keywordtype">char</span> *content_type);</div>
<div class="line"><a name="l00276"></a><span class="lineno">  276</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_gaef1d5966124585b238136326938a6d31.html#gaef1d5966124585b238136326938a6d31" title="Adds an HTTP header to the request.">RestRequest_add_header</a>(<a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a> *<span class="keyword">self</span>, <span class="keyword">const</span> <span class="keywordtype">char</span> *header);</div>
<div class="line"><a name="l00277"></a><span class="lineno">  277</span>&#160;</div>
<div class="line"><a name="l00278"></a><span class="lineno">  278</span>&#160;<span class="preprocessor">#pragma mark RestClient</span></div>
<div class="line"><a name="l00279"></a><span class="lineno">  279</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00281"></a><span class="lineno"><a class="code" href="group__REST__API_ga7c8a0c67e6446d0ae680f5cef1737337.html#ga7c8a0c67e6446d0ae680f5cef1737337">  281</a></span>&#160;<span class="preprocessor">#define CLASS_REST_CLIENT &quot;RestClient&quot;</span></div>
<div class="line"><a name="l00282"></a><span class="lineno">  282</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00291"></a><span class="lineno"><a class="code" href="structRestClient.html">  291</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span>{</div>
<div class="line"><a name="l00293"></a><span class="lineno"><a class="code" href="group__REST__API_ga6e0fae75ec7e35eab6b198ef65d4aa04.html#ga6e0fae75ec7e35eab6b198ef65d4aa04">  293</a></span>&#160;        <a class="code" href="structObject.html" title="The base Object class structure contains the textual name of the class; useful for debugging...">Object</a> <a class="code" href="group__REST__API_ga6e0fae75ec7e35eab6b198ef65d4aa04.html#ga6e0fae75ec7e35eab6b198ef65d4aa04" title="Parent class&#39;s fields.">parent</a>;</div>
<div class="line"><a name="l00298"></a><span class="lineno"><a class="code" href="group__REST__API_gafc21518ea4ec6996d1716420249f99c1.html#gafc21518ea4ec6996d1716420249f99c1">  298</a></span>&#160;        <span class="keywordtype">char</span> *<a class="code" href="group__REST__API_gafc21518ea4ec6996d1716420249f99c1.html#gafc21518ea4ec6996d1716420249f99c1" title="Host name or IP of REST server.">host</a>;</div>
<div class="line"><a name="l00300"></a><span class="lineno"><a class="code" href="group__REST__API_gaa006d5a56c10f17d1c82d0fd3293d211.html#gaa006d5a56c10f17d1c82d0fd3293d211">  300</a></span>&#160;        <span class="keywordtype">int</span> <a class="code" href="group__REST__API_gaa006d5a56c10f17d1c82d0fd3293d211.html#gaa006d5a56c10f17d1c82d0fd3293d211" title="Port number, generally 80 or 443.">port</a>;</div>
<div class="line"><a name="l00302"></a><span class="lineno"><a class="code" href="group__REST__API_ga1414831e16828fef5989884c8b56ab8c.html#ga1414831e16828fef5989884c8b56ab8c">  302</a></span>&#160;        <span class="keywordtype">char</span> *<a class="code" href="group__REST__API_ga1414831e16828fef5989884c8b56ab8c.html#ga1414831e16828fef5989884c8b56ab8c" title="Host name or IP of proxy (NULL disables)">proxy_host</a>;</div>
<div class="line"><a name="l00304"></a><span class="lineno"><a class="code" href="group__REST__API_ga1e15c916347c244f2d96a88c08620d96.html#ga1e15c916347c244f2d96a88c08620d96">  304</a></span>&#160;        <span class="keywordtype">int</span> <a class="code" href="group__REST__API_ga1e15c916347c244f2d96a88c08620d96.html#ga1e15c916347c244f2d96a88c08620d96" title="Use -1 for default.">proxy_port</a>;</div>
<div class="line"><a name="l00306"></a><span class="lineno"><a class="code" href="group__REST__API_gae5e5ec7311b433934f57642663feaadf.html#gae5e5ec7311b433934f57642663feaadf">  306</a></span>&#160;        <span class="keywordtype">char</span> *<a class="code" href="group__REST__API_gae5e5ec7311b433934f57642663feaadf.html#gae5e5ec7311b433934f57642663feaadf" title="User to authenticate with proxy (NULL disables)">proxy_user</a>;</div>
<div class="line"><a name="l00308"></a><span class="lineno"><a class="code" href="group__REST__API_ga269691637a4475619f300ad3aa14a560.html#ga269691637a4475619f300ad3aa14a560">  308</a></span>&#160;        <span class="keywordtype">char</span> *<a class="code" href="group__REST__API_ga269691637a4475619f300ad3aa14a560.html#ga269691637a4475619f300ad3aa14a560" title="Password for proxy user.">proxy_pass</a>;</div>
<div class="line"><a name="l00310"></a><span class="lineno"><a class="code" href="group__REST__API_ga32a9ac16b044aabab9ae6a088fe1b706.html#ga32a9ac16b044aabab9ae6a088fe1b706">  310</a></span>&#160;        <span class="keywordtype">void</span> *<span class="keyword">internal</span>;</div>
<div class="line"><a name="l00311"></a><span class="lineno">  311</span>&#160;} <a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a>;</div>
<div class="line"><a name="l00312"></a><span class="lineno">  312</span>&#160;</div>
<div class="line"><a name="l00313"></a><span class="lineno">  313</span>&#160;</div>
<div class="line"><a name="l00323"></a><span class="lineno">  323</span>&#160;<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *<a class="code" href="group__REST__API_ga0154e04e8109a08aa4a8773199b84648.html#ga0154e04e8109a08aa4a8773199b84648" title="Initializes a RestClient object.">RestClient_init</a>(<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *<span class="keyword">self</span>, <span class="keyword">const</span> <span class="keywordtype">char</span> *host, <span class="keywordtype">int</span> port);</div>
<div class="line"><a name="l00324"></a><span class="lineno">  324</span>&#160;</div>
<div class="line"><a name="l00329"></a><span class="lineno">  329</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_gac68772582c195829e34a4872a5d0343f.html#gac68772582c195829e34a4872a5d0343f" title="Destroys a RestClient object and its shared-state information.">RestClient_destroy</a>(<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *<span class="keyword">self</span>);</div>
<div class="line"><a name="l00330"></a><span class="lineno">  330</span>&#160;</div>
<div class="line"><a name="l00343"></a><span class="lineno">  343</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_ga16e3689da61e8d4be49b0f7bff6fefd1.html#ga16e3689da61e8d4be49b0f7bff6fefd1" title="Configures a RestClient to use a proxy.">RestClient_set_proxy</a>(<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *<span class="keyword">self</span>, <span class="keyword">const</span> <span class="keywordtype">char</span> *proxy_host,</div>
<div class="line"><a name="l00344"></a><span class="lineno">  344</span>&#160;                <span class="keywordtype">int</span> proxy_port, <span class="keyword">const</span> <span class="keywordtype">char</span> *proxy_user, <span class="keyword">const</span> <span class="keywordtype">char</span> *proxy_pass);</div>
<div class="line"><a name="l00345"></a><span class="lineno">  345</span>&#160;</div>
<div class="line"><a name="l00355"></a><span class="lineno"><a class="code" href="group__REST__API_ga87ad9e22b61fc63c7e3d5c86dc1fd6aa.html#ga87ad9e22b61fc63c7e3d5c86dc1fd6aa">  355</a></span>&#160;<span class="keyword">typedef</span> int (*<a class="code" href="group__REST__API_ga87ad9e22b61fc63c7e3d5c86dc1fd6aa.html#ga87ad9e22b61fc63c7e3d5c86dc1fd6aa" title="Handler callback to perform some sort of configuration on a cURL handle before it&#39;s executed (e...">rest_curl_config_handler</a>)(<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *rest, CURL *handle);</div>
<div class="line"><a name="l00356"></a><span class="lineno">  356</span>&#160;</div>
<div class="line"><a name="l00360"></a><span class="lineno"><a class="code" href="structRestPrivate.html">  360</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span>{</div>
<div class="line"><a name="l00362"></a><span class="lineno"><a class="code" href="group__REST__API_ga6c1c6125165d31f0fa3d6fdab8b1c445.html#ga6c1c6125165d31f0fa3d6fdab8b1c445">  362</a></span>&#160;        CURLSH *<a class="code" href="group__REST__API_ga6c1c6125165d31f0fa3d6fdab8b1c445.html#ga6c1c6125165d31f0fa3d6fdab8b1c445" title="Shared-state information for CURL.">curl_shared</a>;</div>
<div class="line"><a name="l00363"></a><span class="lineno">  363</span>&#160;<span class="preprocessor">#ifdef _PTHREADS</span></div>
<div class="line"><a name="l00364"></a><span class="lineno">  364</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00365"></a><span class="lineno">  365</span>&#160;        pthread_mutex_t curl_lock;</div>
<div class="line"><a name="l00366"></a><span class="lineno">  366</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00367"></a><span class="lineno">  367</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00371"></a><span class="lineno"><a class="code" href="group__REST__API_ga798122179571c69da752fe8c2dafa255.html#ga798122179571c69da752fe8c2dafa255">  371</a></span>&#160;        <a class="code" href="group__REST__API_ga87ad9e22b61fc63c7e3d5c86dc1fd6aa.html#ga87ad9e22b61fc63c7e3d5c86dc1fd6aa" title="Handler callback to perform some sort of configuration on a cURL handle before it&#39;s executed (e...">rest_curl_config_handler</a> *<a class="code" href="group__REST__API_ga798122179571c69da752fe8c2dafa255.html#ga798122179571c69da752fe8c2dafa255" title="Array of functions implementing rest_curl_config_handler to configure the low-level CURL request obje...">handlers</a>;</div>
<div class="line"><a name="l00375"></a><span class="lineno"><a class="code" href="group__REST__API_ga8ff264d3cb204ec0f983ede6ee04a55f.html#ga8ff264d3cb204ec0f983ede6ee04a55f">  375</a></span>&#160;        <span class="keywordtype">int</span> <a class="code" href="group__REST__API_ga8ff264d3cb204ec0f983ede6ee04a55f.html#ga8ff264d3cb204ec0f983ede6ee04a55f" title="Number of CURL config handler functions in the array.">curl_config_handler_count</a>;</div>
<div class="line"><a name="l00376"></a><span class="lineno">  376</span>&#160;} <a class="code" href="structRestPrivate.html" title="Internal private state for RestClient.">RestPrivate</a>;</div>
<div class="line"><a name="l00377"></a><span class="lineno">  377</span>&#160;</div>
<div class="line"><a name="l00378"></a><span class="lineno">  378</span>&#160;<span class="preprocessor">#pragma mark Standard Handlers</span></div>
<div class="line"><a name="l00379"></a><span class="lineno">  379</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00386"></a><span class="lineno">  386</span>&#160;<span class="keywordtype">int</span> <a class="code" href="group__REST__API_gab355d76d638f2ea2b09299d0b70436e9.html#gab355d76d638f2ea2b09299d0b70436e9" title="This is a CURL configuration function that enables verbose logging of the request and response via CU...">rest_verbose_config</a>(<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *rest, CURL *handle);</div>
<div class="line"><a name="l00394"></a><span class="lineno">  394</span>&#160;<span class="keywordtype">int</span> <a class="code" href="group__REST__API_ga0de010a1957279cf0c7b9f4e1d734ed3.html#ga0de010a1957279cf0c7b9f4e1d734ed3" title="This is a CURL configuration function that will check the RestClient to see if a proxy is set and con...">rest_proxy_config</a>(<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *rest, CURL *handle);</div>
<div class="line"><a name="l00395"></a><span class="lineno">  395</span>&#160;</div>
<div class="line"><a name="l00405"></a><span class="lineno">  405</span>&#160;<span class="keywordtype">int</span> <a class="code" href="group__REST__API_ga71b3e85801bc1a75c6a9edd867d2cd24.html#ga71b3e85801bc1a75c6a9edd867d2cd24" title="This is a CURL configuration function that will disable SSL certificate validation, including host validation.">rest_disable_ssl_cert_check</a>(<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *rest, CURL *handle);</div>
<div class="line"><a name="l00406"></a><span class="lineno">  406</span>&#160;</div>
<div class="line"><a name="l00415"></a><span class="lineno">  415</span>&#160;<span class="keywordtype">int</span> <a class="code" href="group__REST__API_gaed5e93884f0e6a9e54f13823a1143126.html#gaed5e93884f0e6a9e54f13823a1143126" title="This is an internal CURL configuration function that configures the underlying CURL handle to use sha...">rest_curl_shared_config</a>(<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *rest, CURL *handle);</div>
<div class="line"><a name="l00416"></a><span class="lineno">  416</span>&#160;</div>
<div class="line"><a name="l00417"></a><span class="lineno">  417</span>&#160;<span class="preprocessor">#pragma mark RestFilter</span></div>
<div class="line"><a name="l00418"></a><span class="lineno">  418</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00422"></a><span class="lineno"><a class="code" href="structRestFilterTag.html">  422</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span><a class="code" href="structRestFilterTag.html" title="A linked list of filter functions to apply to the request.">RestFilterTag</a> {</div>
<div class="line"><a name="l00424"></a><span class="lineno"><a class="code" href="group__REST__API_ga6c781ac6f78e228903cbaa7e1e3ebc96.html#ga6c781ac6f78e228903cbaa7e1e3ebc96">  424</a></span>&#160;        <span class="keywordtype">void</span> *<a class="code" href="group__REST__API_ga6c781ac6f78e228903cbaa7e1e3ebc96.html#ga6c781ac6f78e228903cbaa7e1e3ebc96" title="A function pointer implementing rest_http_filter.">func</a>;</div>
<div class="line"><a name="l00429"></a><span class="lineno"><a class="code" href="group__REST__API_ga792379d6dec235c62013ca6f3258c76f.html#ga792379d6dec235c62013ca6f3258c76f">  429</a></span>&#160;        <span class="keyword">struct </span><a class="code" href="structRestFilterTag.html" title="A linked list of filter functions to apply to the request.">RestFilterTag</a> *<a class="code" href="group__REST__API_ga792379d6dec235c62013ca6f3258c76f.html#ga792379d6dec235c62013ca6f3258c76f" title="The next RestFilter to execute.">next</a>;</div>
<div class="line"><a name="l00430"></a><span class="lineno">  430</span>&#160;} <a class="code" href="group__REST__API_ga6dfda164728247ced7d2a7e5b05c131e.html#ga6dfda164728247ced7d2a7e5b05c131e" title="A linked list of filter functions to apply to the request.">RestFilter</a>;</div>
<div class="line"><a name="l00431"></a><span class="lineno">  431</span>&#160;</div>
<div class="line"><a name="l00442"></a><span class="lineno"><a class="code" href="group__REST__API_ga5c554f188123cb53ab48484c36c3a743.html#ga5c554f188123cb53ab48484c36c3a743">  442</a></span>&#160;<span class="keyword">typedef</span> void (*<a class="code" href="group__REST__API_ga5c554f188123cb53ab48484c36c3a743.html#ga5c554f188123cb53ab48484c36c3a743" title="An HTTP request filter.">rest_http_filter</a>)(<a class="code" href="structRestFilterTag.html" title="A linked list of filter functions to apply to the request.">RestFilter</a> *<span class="keyword">self</span>, <a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *rest,</div>
<div class="line"><a name="l00443"></a><span class="lineno">  443</span>&#160;                <a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a> *request, <a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a> *response);</div>
<div class="line"><a name="l00444"></a><span class="lineno">  444</span>&#160;</div>
<div class="line"><a name="l00453"></a><span class="lineno">  453</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_gad0944d101867fb49ed2623f5d7a6cc4a.html#gad0944d101867fb49ed2623f5d7a6cc4a" title="Executes a REST request.">RestClient_execute_request</a>(<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *<span class="keyword">self</span>, <a class="code" href="structRestFilterTag.html" title="A linked list of filter functions to apply to the request.">RestFilter</a> *filters,</div>
<div class="line"><a name="l00454"></a><span class="lineno">  454</span>&#160;                <a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a> *request, <a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a> *response);</div>
<div class="line"><a name="l00455"></a><span class="lineno">  455</span>&#160;</div>
<div class="line"><a name="l00460"></a><span class="lineno">  460</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_ga1137f631a9d1f809a6a124d0de95f0c6.html#ga1137f631a9d1f809a6a124d0de95f0c6" title="Adds a curl config handler to the client.">RestClient_add_curl_config_handler</a>(<a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *boss,</div>
<div class="line"><a name="l00461"></a><span class="lineno">  461</span>&#160;                <a class="code" href="group__REST__API_ga87ad9e22b61fc63c7e3d5c86dc1fd6aa.html#ga87ad9e22b61fc63c7e3d5c86dc1fd6aa" title="Handler callback to perform some sort of configuration on a cURL handle before it&#39;s executed (e...">rest_curl_config_handler</a> handler);</div>
<div class="line"><a name="l00462"></a><span class="lineno">  462</span>&#160;</div>
<div class="line"><a name="l00474"></a><span class="lineno">  474</span>&#160;<a class="code" href="structRestFilterTag.html" title="A linked list of filter functions to apply to the request.">RestFilter</a> *<a class="code" href="group__REST__API_gad2a350560fed1b14418e77831717237f.html#gad2a350560fed1b14418e77831717237f" title="Adds a filter to the head of the filter chain.">RestFilter_add</a>(<a class="code" href="structRestFilterTag.html" title="A linked list of filter functions to apply to the request.">RestFilter</a> *start, <a class="code" href="group__REST__API_ga5c554f188123cb53ab48484c36c3a743.html#ga5c554f188123cb53ab48484c36c3a743" title="An HTTP request filter.">rest_http_filter</a> <a class="code" href="group__REST__API_ga792379d6dec235c62013ca6f3258c76f.html#ga792379d6dec235c62013ca6f3258c76f" title="The next RestFilter to execute.">next</a>);</div>
<div class="line"><a name="l00475"></a><span class="lineno">  475</span>&#160;</div>
<div class="line"><a name="l00480"></a><span class="lineno">  480</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_ga9a142aee13d749dbadc1bb35bccff4ce.html#ga9a142aee13d749dbadc1bb35bccff4ce" title="Frees a filter chain.">RestFilter_free</a>(<a class="code" href="structRestFilterTag.html" title="A linked list of filter functions to apply to the request.">RestFilter</a> *chain);</div>
<div class="line"><a name="l00481"></a><span class="lineno">  481</span>&#160;</div>
<div class="line"><a name="l00482"></a><span class="lineno">  482</span>&#160;<span class="preprocessor">#pragma mark Standard Filters</span></div>
<div class="line"><a name="l00483"></a><span class="lineno">  483</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00493"></a><span class="lineno">  493</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_gabc9a93f9a6ddc2528115853396b485f1.html#gabc9a93f9a6ddc2528115853396b485f1" title="This RestFilter function sets the Content-Type and Content-Length headers on the request and parses t...">RestFilter_set_content_headers</a>(<a class="code" href="structRestFilterTag.html" title="A linked list of filter functions to apply to the request.">RestFilter</a> *<span class="keyword">self</span>, <a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *rest,</div>
<div class="line"><a name="l00494"></a><span class="lineno">  494</span>&#160;                <a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a> *request, <a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a> *response);</div>
<div class="line"><a name="l00495"></a><span class="lineno">  495</span>&#160;</div>
<div class="line"><a name="l00504"></a><span class="lineno">  504</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__REST__API_ga541a53a9ff5697d4fff8accdc999f957.html#ga541a53a9ff5697d4fff8accdc999f957" title="This is usually the last filter in the chain and executes the HTTP request using cURL.">RestFilter_execute_curl_request</a>(<a class="code" href="structRestFilterTag.html" title="A linked list of filter functions to apply to the request.">RestFilter</a> *<span class="keyword">self</span>, <a class="code" href="structRestClient.html" title="Configuration for a RestClient.">RestClient</a> *rest,</div>
<div class="line"><a name="l00505"></a><span class="lineno">  505</span>&#160;                <a class="code" href="structRestRequest.html" title="Defines the RestRequest object.">RestRequest</a> *request, <a class="code" href="structRestResponse.html" title="This is a standard response from REST operations.">RestResponse</a> *response);</div>
<div class="line"><a name="l00506"></a><span class="lineno">  506</span>&#160;</div>
<div class="line"><a name="l00510"></a><span class="lineno">  510</span>&#160;<span class="preprocessor">#endif </span><span class="comment">/* REST_CLIENT_H_ */</span><span class="preprocessor"></span></div>
</div><!-- fragment --></div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li><li class="navelem"><a class="el" href="rest__client_8h.html">rest_client.h</a></li>
    <li class="footer">Generated on Fri Oct 19 2012 13:02:48 for rest_client_c by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.1.1 </li>
  </ul>
</div>
</body>
</html>
